import java.util.Scanner;

public class h_26 {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        System.out.print("输入第一个字母：");
        String str = sc.nextLine();
        switch (str){
            case "S":
                System.out.print("无法判断是Sunday OR Saturday，输入第二个字母");
                String s = sc.nextLine();
                if(s.equals("u")){
                    System.out.println("星期日");
                    break;
                }else if(s.equals("a")){
                    System.out.println("星期六");
                    break;
                }else {
                    System.out.println("输入错误");
                    break;
                }
            case "M":
                System.out.println("星期一");
                break;
            case "T":
                System.out.print("无法判断是Tuesday OR Thursday，输入第二个字母");
                String s2 = sc.nextLine();
                if(s2.equals("u")){
                    System.out.println("星期二");
                    break;
                }else if(s2.equals("h")){
                    System.out.println("星期四");
                    break;
                }else {
                    System.out.println("输入错误");
                    break;
                }
            case "W":
                System.out.println("星期三");
                break;
            case "F":
                System.out.println("星期五");
                break;
            default:
                System.out.println("输入违法");
        }
    }
}
